-- GENERATED SPELL FOR [Astromancer] --


function spell0_20033(pUnit, Event) --@Fire Blast,n/a--
pUnit:FullCastSpellOnTarget(37110,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_20033', 602, 1)
end

function spell1_20033(pUnit, Event) --@Fireball Volley,n/a--
pUnit:FullCastSpellOnTarget(37109,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_20033', 695, 1)
end

function spell2_20033(pUnit, Event) --@Molten Armor,Self--
pUnit:FullCastSpellOnTarget(35915,pUnit)
pUnit:RegisterEvent('Sorts_20033', 514, 1)
end

function spell3_20033(pUnit, Event) --@Molten Armor,n/a--
pUnit:FullCastSpellOnTarget(35916,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_20033', 635, 1)
end

function Sorts_20033(pUnit, Event)
local choix_sorts_20033 = math.random(0, 3)
if choix_sorts_20033 == 0 then
pUnit:RegisterEvent('spell0_20033', 1, 1)
end
if choix_sorts_20033 == 1 then
pUnit:RegisterEvent('spell1_20033', 1, 1)
end
if choix_sorts_20033 == 2 then
pUnit:RegisterEvent('spell2_20033', 1, 1)
end
if choix_sorts_20033 == 3 then
pUnit:RegisterEvent('spell3_20033', 1, 1)
end
end

function mob20033_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_20033', math.random(1500, 3000), 1)
end

function mob20033_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob20033_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob20033_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(20033, 1, 'mob20033_Action')
RegisterUnitEvent(20033, 2, 'mob20033_Leave')
RegisterUnitEvent(20033, 3, 'mob20033_Kill')
RegisterUnitEvent(20033, 4, 'mob20033_Die')
